import { AppState } from '../index';
import { State, todoFeatureKey } from '../reducers/todo.reducer';
import { createFeatureSelector, createSelector } from '@ngrx/store';

export const selectTodo =createFeatureSelector<AppState,State>(todoFeatureKey)
export const selectTodos = createSelector(selectTodo,state=>state.todos)